﻿<%@ Page Title="" Language="vb" AutoEventWireup="false" MasterPageFile="~/Site.Master" CodeBehind="ChineseFoodList.aspx.vb" Inherits="_14073716_Prototype.ChineseFoodList" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <p>
        &nbsp;</p>
    <p>
        <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
            DataSourceID="SqlDataSource1" DataKeyNames="ID" CellPadding="3" 
            BackColor="White" BorderColor="#CCCCCC" BorderStyle="None" 
            BorderWidth="1px" AllowSorting="True">
            <Columns>
                <asp:BoundField DataField="ChineseFoodName_English" 
                    HeaderText="Chinese Food Name English" 
                    SortExpression="ChineseFoodName_English" />
                <asp:BoundField DataField="AreaOfOrigin_English" 
                    HeaderText="Area Of Origin English" 
                    SortExpression="AreaOfOrigin_English" />
                <asp:BoundField DataField="AvgOfRating" HeaderText="Average Of Rating" 
                    ReadOnly="True" SortExpression="AvgOfRating" />
                <asp:TemplateField HeaderText="Go to Detail">
                    <ItemTemplate>
                        <asp:ImageButton ID="ImageButton1" runat="server" Height="100px" 
                            ImageUrl='<%# Eval("Picture", "{0}") %>' 
                            PostBackUrl='<%# Eval("ID", "ChineseFoodDetail.aspx?ID={0}") %>' 
                            Width="100px" />
                    </ItemTemplate>
                </asp:TemplateField>
            </Columns>
            <FooterStyle BackColor="White" ForeColor="#000066" />
            <HeaderStyle BackColor="#006699" Font-Bold="True" ForeColor="White" />
            <PagerStyle ForeColor="#000066" HorizontalAlign="Left" BackColor="White" />
            <RowStyle ForeColor="#000066" />
            <SelectedRowStyle BackColor="#669999" Font-Bold="True" ForeColor="White" />
            <SortedAscendingCellStyle BackColor="#F1F1F1" />
            <SortedAscendingHeaderStyle BackColor="#007DBB" />
            <SortedDescendingCellStyle BackColor="#CAC9C9" />
            <SortedDescendingHeaderStyle BackColor="#00547E" />
        </asp:GridView>
        <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
            ConnectionString="<%$ ConnectionStrings:ChineseFoodConn %>" 
            ProviderName="<%$ ConnectionStrings:ChineseFoodConn.ProviderName %>" 
            SelectCommand="SELECT * FROM [ChineseFoodAndAvgRating]">
        </asp:SqlDataSource>
    </p>
    <p>
        &nbsp;</p>
    </asp:Content>
